<div id="testaut-menu-controller" ng-controller="MenuController">
  <ion-side-menus id="testaut_app_menu" delegate-handle="sideMenu" ng-cloak>
    <ion-side-menu-content>
      <ion-nav-bar class="bar-stable nav-title-slide-ios7">
        <ion-nav-back-button class="button-icon">
          <span class="icon ion-ios7-arrow-left"></span>
        </ion-nav-back-button>
      </ion-nav-bar>
      <ion-nav-view></ion-nav-view>
    </ion-side-menu-content>
    <ion-side-menu>
      <ion-header-bar class="bar bar-header bar-stable">
        <button ng-if="!$root.LoginData.isKiosk" class="button icon ion-person-stalker" ng-click="switchProfiles()"></button>
        <h1 class="title">{{'kMenuOptions'|translate}}</h1>
        </button>
      </ion-header-bar>
      <ion-content has-header="true" mouse-wheel-scroll class="notch-ready">
        <!-- <ion-scroll scrollbar-y="false" style="height:100%" >-->
        <ion-list>
          <!--<ion-item ng-click="navigateView('app.montage')" menu-close>-->
        <!--
          <ion-item  href="#/app/bookmark" ng-click="go('/app/bookmark)')">
            <span class=" item-icon-left">
              <i class="icon ion-bookmark"></i>
            </span>{{'kBookmark'| translate}}
          </ion-item>
        -->
          <ion-item id="testaut_menu_montage" href="#/app/montage" ng-click="go('/app/montage')">

            <!--<span ng-if="$root.runMode=='lowbw'" style="float:right;margin-top:-18px;background-color:#f1c40f;color:#000;font-size:11px;opacity:0.7;width:20px;border-radius: 0px 0px 5px 5px;display:inline-block;text-align:center;">&nbsp;<i class="icon ion-arrow-graph-down-left"></i>&nbsp;</span>-->
            <span class=" item-icon-left">
              <i class="icon ion-grid"></i>
            </span>{{'kMenuMontage'|translate}}
          </ion-item>

            
          <!--<ion-item ng-click="navigateView('app.timeline')" menu-close>-->
          <span ng-if="!$root.LoginData.isKiosk">
          <ion-item id="testaut_menu_timeline" href="#/app/timeline" ng-click="go('/app/timeline')">
            <span class=" item-icon-left">
              <i class="icon ion-android-time"></i>
            </span>{{'kMenuTimeline'|translate}}
          </ion-item>

          <!--<ion-item ng-click="navigateView('app.events', {id:0,playEvent:false,lastCheckTime:''})"  menu-close>-->
          <ion-item id="testaut_menu_events" href="#/app/events/0/false/" ng-click="go('/app/events/0/false/')">
            <span class=" item-icon-left">
              <i class="icon ion-ios-calendar-outline"></i>
            </span>{{'kMenuEvents'|translate}}
          </ion-item>

          <!-- <ion-item  ng-click="navigateView('app.montage-history')" menu-close>-->
              <ion-item id="menu-move-5" href="#/app/montage-history" ng-click="go('/app/montage-history')">
                <span class=" item-icon-left">
                  <i class="icon ion-ios-keypad-outline"></i>
                </span>{{'kMenuEventMontage'|translate}}
              </ion-item>
              
              
          <!--<ion-item  ng-click="navigateView('app.moment')" menu-close>-->
          <ion-item id="menu-move-4" ng-click="go('/app/moment')" href="#/app/moment" ng-click="go('/app/moment')">
            <span class=" item-icon-left">
              <i class="icon ion-star"></i>
            </span>{{'kMoment24Heading'|translate}}
          </ion-item>

         
          <!--<ion-item ng-click="navigateView('app.monitors')" menu-close>-->
          <ion-item id="menu-move-6" href="#/app/monitors" ng-click="go('/app/monitors')">
            <span class=" item-icon-left">
              <i class="icon ion-ios-videocam-outline"></i>
            </span>{{'kMenuMonitors'|translate}}
          </ion-item>

          <!--<ion-item ng-click="navigateView('app.state')" menu-close>-->
          <ion-item id="testaut_menu_state" href="#/app/state" ng-click="go('/app/state')">
            <span class=" item-icon-left">
              <i class="icon ion-information-circled"></i>
            </span> {{'kMenuSystemStatus'|translate}}
          </ion-item>

           
          <!--<ion-item nav-clear menu-close ng-click="navigateView('app.login', {wizard:false})" >-->
          <ion-item id="menu-move-8" nav-clear href="#/app/login/false" ng-click="go('/app/login/false')">
            <span class=" item-icon-left">
              <i class="icon ion-person"></i>
              {{'kMenuZMSettings'|translate}}
              <!--<span class="item-note" style="width:90px">
                                {{$root.getProfileName();}}
                            </span>-->
              <span style="float:right; margin-top:-18px;background-color:#444444;color:#fff;font-size:11px;opacity:0.7;width:90px;border-radius: 0px 0px 5px 5px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;text-align:center;">&nbsp;{{$root.getProfileName();}}&nbsp;</span>
            </span>
          </ion-item>

          

          <ion-item id="menu-move-9" nav-clear href="#/app/devoptions" ng-click="go('/app/devoptions')">
            <!--<ion-item nav-clear menu-close ng-click="navigateView('app.devoptions')">-->
            <span class=" item-icon-left">
              <i class="icon ion-settings"></i>
            </span> {{'kMenuDevSettings'|translate}}
          </ion-item>

            
          <ion-item ng-click="switchLang()" nav-clear menu-close>
            <span class=" item-icon-left">
              <i class="icon ion-earth"></i>
            </span> {{'kLanguage'|translate}}
          </ion-item>

          <!--<ion-item nav-clear menu-close ng-click="navigateView('app.help')" >-->
          <ion-item id="menu-move-10" nav-clear href="#/app/help" ng-click="go('/app/help')">
            <span class=" item-icon-left">
              <i class="icon ion-help"></i>
            </span> {{'kMenuHelp'|translate}}
          </ion-item>



          <!--<ion-item nav-clear menu-close ng-click="navigateView('app.wizard')" >-->
          <ion-item id="menu-move-11" nav-clear href="#/app/wizard" ng-click="go('/app/wizard')">
            <span id="testaut_menu_wizard" class=" item-icon-left">
              <i class="icon ion-wand"></i>
            </span> {{'kMenuWizard'|translate}}
          </ion-item>

          <ion-item ng-click="flushAPICache()" nav-clear menu-close>
            <span class=" item-icon-left">
              <i class="icon ion-trash-a"></i>
            </span> {{'kFlushAllCaches'|translate}}
          </ion-item>


          <div ng-if="$root.showBlog && 0">
            <!--<ion-item nav-clear menu-close ng-click="navigateView('app.news')" >-->
            <ion-item nav-clear menu-close href="#/app/news">
              <span class=" item-icon-left">
                <i class="icon ion-radio-waves"></i>
              </span>{{'kMenuNews'|translate}}
              <span style="color:#268d3a;"> {{$root.newBlogPost}}</span>
            </ion-item>
          </div>

          <!--<ion-item nav-clear menu-close ng-click="navigateView('app.log')" >-->
          <ion-item id="testaut_menu_logs" nav-clear href="#/app/log" ng-click="go('/app/log')">
            <span class=" item-icon-left">
              <i class="icon ion-clipboard"></i>
            </span> {{'kMenuLogs'|translate}}
          </ion-item>

          <div ng-if="$root.newVersionAvailable &&  $root.platformOS=='desktop'">
            <ion-item nav-clear menu-close href="">
              <span class=" item-icon-left">
                <i class="icon ion-email-unread"></i>
              </span>
              <span style="color:#268d3a;">{{$root.newVersionAvailable}}</span>
            </ion-item>
          </div>

          <div ng-if="$root.platformOS=='android'">
            <ion-item ng-click="$root.exitApp();">
              <span class=" item-icon-left">
                <i class="icon ion-close-circled"></i>
              </span> {{'kMenuExit'|translate}}
            </ion-item>
          </div>
          <ion-item style="color:rgb(106, 106, 106); font-size:90%;">
            <i class="ion-ios-location"></i> {{$root.getLocalTimeZone();}}
            <br />
            <span ng-if="$root.isTzSupported()">
              <i class="icon icon-server"></i> {{$root.getServerTimeZoneNow();}} </span>
          </ion-item>
        </span>
        <ion-item ng-if="$root.LoginData.isKiosk" ng-click="exitKiosk()">
          <i class="ion-unlocked"></i> {{'kKioskModeExit' | translate}}
        </ion-item>
        </ion-list>
        <!--</ion-scroll>-->
      </ion-content>
    </ion-side-menu>
  </ion-side-menus>
</div>
